<div class="col-sm-12 mt20">

    <div class="panel panel-default">
        <div class="panel-body" ng-keyup="myKeyup($event)">
            <div class="col-xs-12 row">
                <div class="col-sm-2">
                    <input type="text" class="form-control" placeholder="卡面号" ng-model="searchform.smart_card_no">
                </div>
                <div class="col-sm-2">
                    <input type="text" class="form-control" placeholder="商品名" ng-model="searchform.title">
                </div>
                <div class="col-sm-2">
                    <input type="text" class="form-control" placeholder="设备号" ng-model="searchform.device_code">
                </div>
                <div class="col-sm-2">
                    <input type="text" class="form-control" datepicker-popup="yyyy-MM-dd" ng-model="period_start.value" is-open="period_start.opened"
                        ng-click="dateOpen($event, period_start)" placeholder="开始时间" ng-required="true" close-text="关闭" current-text="今天"
                        clear-text="清除" readonly/>
                </div>
                <div class="col-sm-2">
                    <input type="text" class="form-control" datepicker-popup="yyyy-MM-dd" ng-model="period_end.value" is-open="period_end.opened"
                        ng-click="dateOpen($event, period_end)" placeholder="结束时间" ng-required="true" close-text="关闭" current-text="今天"
                        clear-text="清除" readonly/>
                </div>
                <div class="col-sm-2">
                    <button class="btn btn-info search btn-block" ng-click="loadlist()">立即搜索</button>
                </div>
            </div>
            <div class="col-xs-12 row mt20">
                <div class="col-sm-2">
                    <input type="text" class="form-control" placeholder="商品编号" ng-model="searchform.sale_code">
                </div>
                <div class="col-sm-2">
                    <ui-select ng-model="searchform.sale_category" theme="bootstrap">
                        <ui-select-match placeholder="产品类型">{{$select.selected.name}}</ui-select-match>
                        <ui-select-choices repeat="item.code as item in sale_category_list | filter: $select.search">
                            <span ng-bind-html="item.name | highlight: $select.search"></span>
                        </ui-select-choices>
                    </ui-select>
                </div>
                <div class="col-sm-2">
                    <input type="number" class="form-control" placeholder="最低次数" ng-model="searchform.small_num">
                </div>
                <div class="col-sm-2">
                    <input type="number" class="form-control" placeholder="最高次数" ng-model="searchform.big_num">
                </div>
                <div class="col-sm-2"></div>
                <div class="col-sm-2"></div>
            </div>
        </div>

        <div class="panel-body">
            <table class="table table-striped table-bordered dataTable table-condensed tree_table" style="table-layout:fixed">
                <thead>
                    <tr>
                        <th class="col-md-1 text-center">卡面号</th>
                        <th class="col-md-1 text-center">商品名</th>
                        <th class="col-md-1 text-center">订单数量</th>
                        <th class="col-md-1 text-center">购买/退回</th>
                        <th class="col-md-1 text-center">支付金额</th>
                        <th class="col-md-1 text-center">充值金额</th>
                        <th class="col-md-1 text-center">退款金额</th>
                    </tr>
                </thead>
                <tbody>
                    <tr ng-repeat="card in cardList">
                        <td class="text-center">{{card.smart_card_no}}</td>
                        <td class="text-center">{{card.sale_name}}</td>
                        <td class="text-center">{{card.num}}</td>
                        <td class="text-center">{{card.sale_num}}/{{card.back}}</td>
                        <td class="text-center">{{card.pay_fee}}</td>
                        <td class="text-center">{{card.recharge? card.recharge: '-'}}</td>
                        <td class="text-center">{{card.back_pay_fee? card.back_pay_fee: '-'}}</td>
                    </tr>
                </tbody>
            </table>
        </div>

        <div class="text-right" style="background-color: white; margin-right: 30px">
            <pagination total-items="totalItems" ng-model="currentPage" ng-change="loadlist()" previous-text="上一页" next-text="下一页" first-text="首页"
                last-text="尾页" max-size="5" boundary-links="true" rotate="false" items-per-page="itemsPerPage" class="m-t-none m-b"></pagination>
        </div>

    </div>
</div>